Move back actors that were adopted from mutter (window_group,
top_window_group, the feedback group) from the uiGroup to the stage, and
then destroy the uiGroup. This will tear down more or less all of GNOME
Shells actors gracefully.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1349>
global.stage.remove_actor(global.window_group);
this.uiGroup.add_actor(global.window_group);
+ global.connect('shutdown', () => {
+ const adoptedUiGroupActors = [
+ global.window_group,
+ global.top_window_group,
+ Meta.get_feedback_group_for_display(global.display),
+ ];
+
+ for (let adoptedActor of adoptedUiGroupActors) {
+ this.uiGroup.remove_actor(adoptedActor);
+ global.stage.add_actor(adoptedActor);
+ }
+
+ this.uiGroup.destroy();
+ });
// Using addChrome() to add actors to uiGroup will position actors
// underneath the top_window_group.